import System
import Numeric

fibonacci = 0 : fibonacci_list 0 1

fibonacci_list prev1 prev2 =
    new_fib : fibonacci_list new_fib prev1
    where
        new_fib = prev1 + prev2


fibonacci_str count =
    unwords (map show (take count fibonacci))

main =
    do
        argv_list <- getArgs
        let count = (read (head argv_list)) + 1 :: Int
        putStr ((fibonacci_str count) ++ " ...\n")
